//
//  HHCreateChatDemoViewController.m
//  HHChatKit
//
//  Created by Henry on 2021/8/17.
//

#import "HHCreateChatDemoViewController.h"

@interface HHCreateChatDemoViewController ()

@end

@implementation HHCreateChatDemoViewController

- (void)viewDidLoad {
    [super viewDidLoad];

    NSMutableArray *arr = [NSMutableArray array];
    for (int i = 0; i < 3; i ++) {
        HHSelectUserModel *model = [[HHSelectUserModel alloc] init];
        model.name = [NSString stringWithFormat:@"姓名-%d", i];
        model.userId = [NSString stringWithFormat:@"1%d", i];
        [arr addObject:model];
    }
    for (int i = 0; i < 3; i ++) {
        HHSelectUserModel *model = [[HHSelectUserModel alloc] init];
        model.name = [NSString stringWithFormat:@"没姓名-%d", i];
        model.userId = [NSString stringWithFormat:@"2%d", i];
        [arr addObject:model];
    }
    for (int i = 0; i < 10; i ++) {
        HHSelectUserModel *model = [[HHSelectUserModel alloc] init];
        model.name = [NSString stringWithFormat:@"好姓名-%d", i];
        model.userId = [NSString stringWithFormat:@"3%d", i];
        [arr addObject:model];
    }
    
    for (int i = 0; i < 10; i ++) {
        HHSelectUserModel *model = [[HHSelectUserModel alloc] init];
        model.name = [NSString stringWithFormat:@"牛姓名-%d", i];
        model.userId = [NSString stringWithFormat:@"4%d", i];
        [arr addObject:model];
    }
    self.dataArray = arr;
    self.headerArray = @[@"1", @"2"].mutableCopy;
    self.hasIndexSearch = YES;

    [self reloadData];
    [self reloadSelectData];
    
}

@end
